<?php


namespace Xiaoguai\DesignPattern\DP015;


abstract class AbstractBuilder
{
    /**
     * @var Product $product
     */
    protected $product;

    public function __construct()
    {
        $this->product = new Product();
    }

    // 构建
    abstract public function buildPartA();
    abstract public function buildPartB();
    abstract public function buildPartC();

    // 返回
    public function getResult()
    {
        return $this->product;
    }
}